//
//  ViewController.m
//  DemoJSPatch
//
//  Created by 唐可雄 on 16/10/18.
//  Copyright © 2016年 swustyc. All rights reserved.
//

#import "ViewController.h"

@interface ViewController () {
    NSArray *_data;
}

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
    
    _data = @[@"Item1", @"Item2", @"Item3"];
}


- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

#pragma mark - UITableViewDataSource

- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView {
    return 1;
}

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
    return 4;
}

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"cellItem"];
    
    cell.textLabel.text = _data[indexPath.row];
    
    return cell;
}


@end
